import { GImage } from './GImage'
//资源
export class Resources {
    //所用到的图片
    static images: GImage[] = [
        new GImage(require('@/assets/magic/1.png').default),
        new GImage(require('@/assets/magic/2.png').default),
        new GImage(require('@/assets/magic/3.png').default),
        new GImage(require('@/assets/magic/4.png').default),
        new GImage(require('@/assets/magic/5.png').default),
        new GImage(require('@/assets/magic/6.png').default),
        new GImage(require('@/assets/magic/7.png').default),
        new GImage(require('@/assets/magic/8.png').default),
        new GImage(require('@/assets/magic/9.png').default),
        new GImage(require('@/assets/magic/10.png').default),
    ]
    //等待资源加载
    static async loaded() {
        await Promise.all(this.images.map(m => m.loaded()));
        console.log('资源加载完毕')
    }

}